package com.easylinkin.linkappapi.elasticsearch.service;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;

import com.easylinkin.linkappapi.elasticsearch.entity.BankAlarmNotice;
import com.easylinkin.linkappapi.elasticsearch.entity.BankEnergyAlarmRule;

import java.util.List;


/**
 * <p>
 * 银行能源告警规则
 * </p>
 *
 * @author Xuguoqing
 * @since 2020-04-15
 */
public interface IBankAlarmRuleService extends IService<BankEnergyAlarmRule> {


    /**
     * 创建告警规则
     *
     * @param bankEnergyAlarmRule
     * @return
     */
 boolean  createRule(BankEnergyAlarmRule bankEnergyAlarmRule);


	 /**
	  * 更新告警规则
	  *
	  * @param bankEnergyAlarmRule
	  * @return
	  */
 boolean  updateRule(BankEnergyAlarmRule bankEnergyAlarmRule);

	 /**
	  * 暂停告警规则
	  *
	  * @param bankEnergyAlarmRule
	  * @return
	  */
 boolean  pauseRule(BankEnergyAlarmRule bankEnergyAlarmRule);

	 /**
	  * 重启告警规则
	  *
	  * @param bankEnergyAlarmRule
	  * @return
	  */
 boolean  resumeRule(BankEnergyAlarmRule bankEnergyAlarmRule);
	 
	 /**
	  * 删除告警规则 数据源删除的时候调用
	  *
	  * @param bankEnergyAlarmRule
	  * @return
	  */
 boolean  removeRule(BankEnergyAlarmRule bankEnergyAlarmRule);
 
 
 IPage<BankAlarmNotice> getAlarmNoticePage(Page page, BankAlarmNotice alarmNotice);

 List<BankEnergyAlarmRule> getBankAlarmRuleByDataSourceId(BankEnergyAlarmRule rule);

 
}
